Skip to content

Add the Chen et al. (GraphSfM, arXiv:1912.10659) baseline - #1191

Open
suhanpark wants to merge 1 commit into
masterfrom
gb-parallel-sfm
Open

suhanpark wants to merge 1 commit into
masterfrom
gb-parallel-sfm

Conversation

@suhanpark

Copy link
Copy Markdown
Collaborator

Run the Chen et al. (GraphSfM, arXiv:1912.10659, Sections 3.1–3.2, Algorithms 1 and 2) image clustering, MaxST subgraph expansion, and MinST + MHT sub-model merging baseline from a verified COLMAP database through sparse reconstruction, mirroring the verified-database architecture of #1189.

The runner snapshots the filtered input database (frontend.db + frontend_sha256), preserves local camera intrinsics into global triangulation and final sparse BA, supports Olsson, YFCC-IMB, and streaming Bundler .out reference poses, and records camera coverage, tree diagnostics, stage timings, and pose AUC with GTSfM's evaluator.

This is a single-host implementation using PyCOLMAP for local incremental mapping, global triangulation, and final sparse BA, and GTSAM Similarity3/Pose3/Rot3 for pairwise alignment and spanning-tree merging. Pairwise Sim(3) estimation uses 2-camera minimal RANSAC hypotheses refitted with chordal SO(3) orientation averaging and optimal scale/translation to avoid collinear camera-center roll ambiguity and survive catastrophically diverged local poses. The benchmark notes describe how it differs from the paper and how to reproduce each fixture.

Files added (4 files, existing GTSfM code unchanged)

  • gtsfm/averaging/graph_sfm.py — NCut + Kruskal MaxST expansion, pairwise RANSAC Sim(3) + symmetric msd, Kruskal MinST + MHT anchor merging.
  • scripts/run_graph_sfm.py — Standalone verified-COLMAP-database runner and evaluator.
  • tests/averaging/test_graph_sfm.py — 8 unit and regression tests (clustering/expansion, outlier-resistant Sim(3), catastrophic scale outliers, symmetric msd, MHT anchor tie-breaking, MinST cycle filtering, WAL-safe snapshots, Bundler pose parsing).
  • docs/benchmarks/chen2020_graph_sfm.md — Reproduction commands, paper differences, and observed results.

Validation

  • Tests & lint: All 27 tests in tests/averaging/ (8 new + 19 existing) and the CI flake8 check pass on a clean origin/master checkout.
  • Lund Door (--max-cameras 6 --min-pair-inliers 3800): 3-cluster chain (msd = 0.0452, 0.0763), MHT anchor 1, retained 12/12 cameras and 11,125 points with AUC@5° of 0.9100 after merging and 0.9070 after final BA (0.9131 with --fix-final-intrinsics; single-model PyCOLMAP on same DB: 0.9064).
  • Reichstag (--max-cameras 6, CPU SIFT DB): Re-running on the same frozen frontend.db reproduced cluster membership, msd, point count, and pose AUC bit-for-bit. Unbounded overlap (C=0.5) retained 10/10 cameras with AUC@5° 0.5245 (single-model PyCOLMAP: 0.5254); bounded overlap (C=0.4, O_max=4) exercised a 2-cluster merge (msd = 1.5437, AUC@5° 0.2932 → 0.1985, reflecting local self-calibration variance on 9- and 5-camera subsets).
  • Dubrovnik6K (120-image Old Town subset) (--max-cameras 50 --completeness-ratio 0.5 --max-overlap 20, evaluated against bundle.orig.out): Exercised a 4-cluster graph with a cycle (0–2–3–0 + 1–3), Kruskal MinST dropped the higher-MSD cycle edge (0, 3), and MHT selected anchor cluster 3 by size tie-break (60 > 30). Retained 114/120 cameras and 21,656 points in 69.3 s sequentially with AUC@5° 0.5216 (@10° = 0.6712, @20° = 0.7732) vs single-model PyCOLMAP (multiple_models=True) at 115/120 cameras, 21,577 points, 94.4 s, AUC@5° 0.5550.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant